package ru.spb.nicetu.altx.mnemo.utils.xmlsettings;

import java.io.File;


public abstract class AFileDomSimpleSettingsDocument extends ABaseDomSimpleSettingsDocument {

  @Override
  protected ISettingsDocument createSettingDoc() {
    return new AFileDomSettingsDocument(true) {
      @Override
      protected File getExistingXMLLFile() {
        return AFileDomSimpleSettingsDocument.this.getExistingXMLLFile();
      }
    };
  }

  abstract protected File getExistingXMLLFile();


//  protected File getExistingXMLLFile() {
//    File settingsDir = m_workspaceRoot.getLocation().append(SETTINGS_DIR)
//        .toFile();
//    if (!settingsDir.exists())
//      settingsDir.mkdirs();
//
//    File ioFile = m_workspaceRoot.getLocation().append(SETTINGS_DIR).append(
//        FILE_NAME).toFile();
//    if (!ioFile.exists()) {
//      try {
//        ioFile.createNewFile();
//      } catch (IOException e) {
//        e.printStackTrace();
//      }
//    }
//    return ioFile;
//  }





}
